# Contributor: jane400 <alpine@j4ne.de>
# Maintainer: team/gnome <newbyte@postmarketos.org>
pkgname=gnome-text-editor
pkgver=47.1
pkgrel=0
pkgdesc="A simple text editor for GNOME"
url="https://apps.gnome.org/TextEditor"
arch="all !s390x"
license="GPL-3.0-or-later"
makedepends="
	desktop-file-utils
	editorconfig-dev
	enchant2-dev
	glib-dev
	gtk4.0-dev
	gtksourceview5-dev
	itstool
	libadwaita-dev
	libspelling-dev
	meson
	"
checkdepends="
	appstream-glib
	"
subpackages="$pkgname-doc $pkgname-lang"
source="https://gitlab.gnome.org/GNOME/gnome-text-editor/-/archive/$pkgver/gnome-text-editor-$pkgver.tar.gz"

build() {
	abuild-meson \
		-Db_lto=true \
		-Dbugreport_url="https://gitlab.alpinelinux.org/alpine/aports/-/issues" \
		. output
	meson compile -C output
}

check() {
	meson test --no-rebuild --print-errorlogs -C output
}

package() {
	DESTDIR="$pkgdir" meson install --no-rebuild -C output
}

sha512sums="
c2a33cc47f2d39893f0dc017d965bc26aaee17af8a81c4ff002c8858c828b6502de61cb1c50fe72bb851f0c13e90a0caf04f01deb1ccf9de3bd91e99f60b9cae  gnome-text-editor-47.1.tar.gz
"
